$size: 36px;
$offset: 2 * 3.14159265359 * 16;
$duration: 1.5s;

@keyframes rotator {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(270deg);
  }
}

@keyframes dash {
  0% {
    stroke-dashoffset: $offset;
  }
  50% {
    stroke-dashoffset: $offset / 4;
    transform: rotate(135deg);
  }
  100% {
    stroke-dashoffset: $offset;
    transform: rotate(450deg);
  }
}

svg.loading {
  position: relative;
  display: block;
  width: $size;
  height: $size;
  animation: rotator $duration linear infinite;

  > circle {
    stroke-dasharray: $offset;
    stroke-dashoffset: 0;
    transform-origin: center;
    stroke: $__colorScheme;
    animation: dash $duration ease-in-out infinite;
  }
}

@import "../dark/include/loading";
@import "../highContrast/include/loading";